package gui;

import javax.microedition.lcdui.Graphics;
import logic.MainMidlet;
import logic.Point;

/**
 * screen for showing statistics of the game
 * @author Rekin
 *
 */
public class HighscoresScreen extends ImageAndOkScreenTemplate {
	private String line1;
	private String line2;
	
	/**
	 * default constructors
	 */
	public HighscoresScreen(){
		//ok = new CanvasButton(60, 25, new Point(getWidth()/2-30, getHeight()/2+25), "Ok");
		line1 ="Rounds played: "+MainMidlet.getMidletInstance().stats.getGamesPlayed();
		line2 ="Rounds won: "+MainMidlet.getMidletInstance().stats.getHumanVictories();
	}
	
	/**
	 * @Override
	 * does some additional paintings after the super class
	 */
	protected void paint(Graphics g) {
		super.paint(g);
		g.setColor(200,50,50);
		g.drawString(line1, getWidth()/2, getHeight()/3, Graphics.BASELINE | Graphics.HCENTER);
		g.drawString(line2, getWidth()/2, getHeight()/3+25, Graphics.BASELINE | Graphics.HCENTER);
	}
}
